November 14th, 2012, 11:57 AM
PhpMyAdmin View Question
Hello - I hope I'm posting this question in the correct place.
I'm using phpMyAdmin and trying to create a very simple view.
Following is the SQL as I "save" it:
When I execute the above syntax it works just fine, and returns the records I expect it to return. However... once I save the above syntax as a VIEW, the VIEW returns 0 records. Upon further research, I've found that the above syntax saves as follows:
SELECT UserSites_Tbl.User_ID AS SiteUser
WHERE (((UserSites_Tbl.SiteName)="MySite") AND ((UserSites_Tbl.UserCategory) LIKE "Org%"))
No matter what I do when "saving" my original syntax, it actually "saves" as the second snippet (hence a result of 0 records).
SELECT`UserSites_Tbl`.`User_ID` AS `SiteUser`
WHERE ((`UserSites_Tbl`.`SiteName` = 'MySite') AND (`UserSites_Tbl`.`UserCategory` LIKE '\0\0\0O\0\0\0r\0\0\0g\0\0\0%'))
Does anyone have any ideas as to how I can save the view without it corrupting the Like "Org%" to like '\0\0\0O\0\0\0r\0\0\0g\0\0\0%'?
Thanks in advance -