Re: [PHP-DB] PHP and Oracle
You use // to comment, that is quite fine, but it could be that I can't see the layout of the file rightly, but when I opened the file it looked like this: // echo ( ; // echo ... etc... that won't work if you want to comment a block out you can much better use this kind of commenting out: /* echo ( ); echo (blah); */ check out if that works... Met vriendelijke groet, Michiel Lange ActuEra B.V. GEORGINA ELAINE BAILEYTo: [EMAIL PROTECTED] [EMAIL PROTECTED] cc: .uk Fax to: Subject: [PHP-DB] PHP and Oracle 19-10-2001 19:26 Can anyone tell me why my results will display when I just use text, but won't display when I try to put them into a table. I keep getting a message saying there is a parse error on line 50 of my script, but as far as I acn see, line 50 is commented out. Georgina(See attached file: search1.php4)(See attached file: search1.html) -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] sybase remote procedure ergebnis in variable
anyone who can translate this? Met vriendelijke groet, Michiel Lange ActuEra B.V. 7k stefan.siebenkittel@contr To: [EMAIL PROTECTED] olware.de cc: Fax to: 19-09-2001 12:50 Subject: [PHP-DB] sybase remote procedure ergebnis in variable Hallo, ich nutze per ODBC eine remote procedure auf einem Sybase Server. Die Prozedur liefert mir unter anderem eine Variable zurück, die ich in PHP weiternutzen muß. Kann mir jemand einen Hinweis geben, wie ich die Variable der ODBC Abfrage in eine PHP Variable übertragen kann? Hier das Beispiel: odbc_exec ($conn,declare @VARIABLE int exec PROZEDURNAME 'TABELLENNAME_SPALTENNAME', @VARIABLE output); @VARIABLE soll übertragen werden in $VARIABLE Danke im voraus 7k -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: Antw: Re: [PHP-DB] sybase remote procedure ergebnis in variable
Missed that... Try these: $VARIABLE = odbc_exec(...) or try what $@VARIABLE contains... Met vriendelijke groet, Michiel Lange ActuEra B.V. Stefan Siebenkittel Stefan.Siebenkittel@contr To: [EMAIL PROTECTED] olware.de cc: Fax to: 19-09-2001 13:55 Subject: Antw: Re: [PHP-DB] sybase remote procedure ergebnis in variable Hi, I posted my question separately in english too: Hi, I run a remote procedure via ODBC on a sybse server. The procedure returns an integer in a variable @VARIABLE. I have to use the integer as a variable $VARIABLE in PHP. Does anybody know how to get the content of @VARIABLE into $VARIABLE? This is the code I use: odbc_exec ($conn,declare @VARIABLE int exec PROZEDURNAME 'TABELLENNAME_SPALTENNAME', @VARIABLE output); content of @VARIABLE must be written into $VARIABLE Thanks in advance 7k [EMAIL PROTECTED] 09/19 1:30 anyone who can translate this? Met vriendelijke groet, Michiel Lange ActuEra B.V. 7k stefan.siebenkittel@contr To: [EMAIL PROTECTED] olware.de cc: Fax to: 19-09-2001 12:50 Subject: [PHP-DB] sybase remote procedure ergebnis in variable Hallo, ich nutze per ODBC eine remote procedure auf einem Sybase Server. Die Prozedur liefert mir unter anderem eine Variable zurück, die ich in PHP weiternutzen muß. Kann mir jemand einen Hinweis geben, wie ich die Variable der ODBC Abfrage in eine PHP Variable übertragen kann? Hier das Beispiel: odbc_exec ($conn,declare @VARIABLE int exec PROZEDURNAME 'TABELLENNAME_SPALTENNAME', @VARIABLE output); @VARIABLE soll übertragen werden in $VARIABLE Danke im voraus 7k -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] Re: postgresql groups and users
I finally had the time to check it out, your solution should be really close... to clarify: - one user can be the member of many groups - one group can have many members I thought that was n on m relation, but oh well :) Anyways: there's no relation groups, but instead a pg_group and pg_user (real database users, no new table users or groups, I wanted to eliminate that one) so in postgresql I do: \d pg_group And the outcome is something like this (it's on another computer, so I could not copy paste) Attribute Type (modifier, but there are none) groname name grousysid integer grolistinteger[] (- those are square brackets in case it's hard to see) Indeces: pg_group_name_index, pg_group_sysid_index When I tried to do a: SELECT * FROM pg_group WHERE grolist='1005'; I get this error: ERROR: array_in: Need to specify dimension I think there's my problem, I don't know how to do that... (I do my queries always first in pgsql first, then I parse them to php, to make sure the query will work) When I do a SELECT * FROM pg_group; I get this list: groname grosysid grolist admins 1 {1004} coders 5 {1006, 1005} areas 4 {1006,1005} Now I want the user that logs in with his/her name, and has uid 1005, to get the options that belong to the groups he's member of. So I need to filter something like this: SELECT * FROM pg_group WHERE his uid is in the grolist; but how can I manage that? Hope I have been clearer this time... Steve Brett steve.brett@e- To: [EMAIL PROTECTED] mis.co.ukcc: Fax to: 05-09-2001Subject: Re: postgresql groups and users 15:24 Michiel Lange [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... for my application in php I connect with a postgresql database. In this database I have made users and groups, where 1 user can be the member of many groups (n on m relation) ^^^ 1 to many. 1 n. That works, but how do I let php find out if a user is a member of a certain group? do a select . i'm assuming that you post the user id into the groups tables. select * from goups where group_id=7 and user_id=1; if the query returns any results then you have a match. so : $numrows=pg_numrows($query); if ($numrows0){printYou have a matchbr;} Steve -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] postgresql groups and users
for my application in php I connect with a postgresql database. In this database I have made users and groups, where 1 user can be the member of many groups (n on m relation) That works, but how do I let php find out if a user is a member of a certain group? I tried to get the relation out of the database and that worked, as far as that I got a list like { group1, group2, group3 } (it's been a while, and I write this from heart) A solution (I was not happy with) was making users, and create a special table with users and a table with groups and create a table that has both user and group as the primary key, so there was a n on m relation possible. In the group database I put a username and password (which is why I don't like the solution) that should log into the database. The whole reason is that I create buttons, and people who don't have the rights should not even see the buttons... Anyone who can help me out? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]