I see two approaches:
1) Write a bit of (PHP/PERL/...) code that performs the query and checks the
number of results (0=not found, 1 = found).
2) Upgrade the query to SELECT COUNT(*) FROM ...
where the result would be 0 for not found and 1 (or more???) for found.
On 5/2/06, Brian Carpenter <hopespoppa(a)gmail.com> wrote:
What php code is needed to determine if "394433" exists at the end of any
username?
myphpadmin created the following sql:
SELECT * FROM `user`WHERE `user_name` LIKE CONVERT( _utf8 '%395523%'USING
latin1 )
but I can't find any meta article explaining how to make such a query and
return a boolean value:
This would be used to trigger a rename_user function.
Overview-
Our Single Sign-on process provides a unique username in the form of
firstname_lastname_ID (the ID never changes but the name could due to
marriage).
If this username exists within MediaWiki, the user is logged-in. If not,
an
extension creates a new user. I need the above check(and rename_user
function) prior to creating a new user.
This is a tangent discussion to
"Best strategy to populate User data from Single Sign On?"
http://mail.wikipedia.org/pipermail/mediawiki-l/2006-April/011719.html
but may apply to a wider audience....
Thanks in advance for any response..
bc
_______________________________________________
MediaWiki-l mailing list
MediaWiki-l(a)Wikimedia.org
http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
--
----
Met vriendelijke groeten / With kind regards
Hans Voss
---------------------------------------
skype: hans.voss
google talk enabled
I am looking for people to invite to Gmail. I have 100 invitations left.