username / password strangeness

classic Classic list List threaded Threaded
21 messages Options
12
Reply | Threaded
Open this post in threaded view
|

username / password strangeness

kimonostereo
Hi all,

I have a strange issue with username and passwords on two different Filemaker db's.

They are each set up the same in FM and in Lasso and are using the same lasso code.

However with one of the db's it works as it should:  It only returns data when a username and password are entered.

On the other db, it will return data when the password field is blank!
It will also return null if I type in the incorrect password.

Here's my lasso code for the display data page:

[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
[Inline:
-Database='reg-8',
-table='table',
-rx,
'username' = '=="'+$username+'"',
-rx,
'password' = '=="'+$password+'"',
-username='search',
-password='xxxxxx',
-keyvalue=KeyField_Value,
-search]

If: (Found_Count) == 1]

Hello [Field: 'student_firstname'] [Field: 'student_lastname']

[Else]
Sorry! Wrong password!
[/If]
[/inline]

I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.

I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.

Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?

\\scott\\
#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

kimonostereo
I've put this into my display page and it works now.

[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
[Inline:
-Database='registration-eight',
-table='table',
-rx,
'username' = '=="'+$username+'"',
-rx,
'password' = '=="'+$password+'"',
-username='search',
-password='xxxxxxx',
-search]

[If: (Error_CurrentError) != (Error_NoError)]An error has occurred. ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
[if: ($password)->size < 1]

        Please enter a password!

        [else]

[if: ($username)->size < 1]

        Please enter a username!

        [else]

[If: (Found_Count) == 1]

Hello [Field: 'student_firstname'] [Field: 'student_lastname']

        [else]

Sorry! Wrong password!

[/If]
[/If]
[/If]
[/inline]

So i guess I'm just wondering: isn't my inline supposed to only return exact matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?


On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:

> Hi all,
>
> I have a strange issue with username and passwords on two different Filemaker db's.
>
> They are each set up the same in FM and in Lasso and are using the same lasso code.
>
> However with one of the db's it works as it should:  It only returns data when a username and password are entered.
>
> On the other db, it will return data when the password field is blank!
> It will also return null if I type in the incorrect password.
>
> Here's my lasso code for the display data page:
>
> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
> [Inline:
> -Database='reg-8',
> -table='table',
> -rx,
> 'username' = '=="'+$username+'"',
> -rx,
> 'password' = '=="'+$password+'"',
> -username='search',
> -password='xxxxxx',
> -keyvalue=KeyField_Value,
> -search]
>
> If: (Found_Count) == 1]
>
> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>
> [Else]
> Sorry! Wrong password!
> [/If]
> [/inline]
>
> I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.
>
> I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>
> Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?
>
> \\scott\\
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

Israel Thompson
Again.. I'm not familiar with how inlines in FMP are normally supposed
to look, but those inlines you've provided look very awkward to me.
You can use regexp "==" in FMP?

Try taking a look at the other available operators besides "-rx" here:
http://reference.lassosoft.com/Reference.LassoApp?302

I believe you may be able to use -eq, 'password'=$password instead of
-rx, 'password' = '=="' + $password + '"'

Izz



On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:

> I've put this into my display page and it works now.
>
> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
> [Inline:
> -Database='registration-eight',
> -table='table',
> -rx,
> 'username' = '=="'+$username+'"',
> -rx,
> 'password' = '=="'+$password+'"',
> -username='search',
> -password='xxxxxxx',
> -search]
>
> [If: (Error_CurrentError) != (Error_NoError)]An error has occurred. ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
> [if: ($password)->size < 1]
>
>        Please enter a password!
>
>        [else]
>
> [if: ($username)->size < 1]
>
>        Please enter a username!
>
>        [else]
>
> [If: (Found_Count) == 1]
>
> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>
>        [else]
>
> Sorry! Wrong password!
>
> [/If]
> [/If]
> [/If]
> [/inline]
>
> So i guess I'm just wondering: isn't my inline supposed to only return exact matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?
>
>
> On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>
>> Hi all,
>>
>> I have a strange issue with username and passwords on two different Filemaker db's.
>>
>> They are each set up the same in FM and in Lasso and are using the same lasso code.
>>
>> However with one of the db's it works as it should:  It only returns data when a username and password are entered.
>>
>> On the other db, it will return data when the password field is blank!
>> It will also return null if I type in the incorrect password.
>>
>> Here's my lasso code for the display data page:
>>
>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>> [Inline:
>> -Database='reg-8',
>> -table='table',
>> -rx,
>> 'username' = '=="'+$username+'"',
>> -rx,
>> 'password' = '=="'+$password+'"',
>> -username='search',
>> -password='xxxxxx',
>> -keyvalue=KeyField_Value,
>> -search]
>>
>> If: (Found_Count) == 1]
>>
>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>
>> [Else]
>> Sorry! Wrong password!
>> [/If]
>> [/inline]
>>
>> I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.
>>
>> I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>>
>> Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?
>>
>> \\scott\\
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

kimonostereo
Hi Izz,

I'm using what Steve Piercy suggested in his Oct 13 email.

The -RX operator passes raw FM search expressions as a query.
For usernames and password, he suggested using "==" to match the entire field instead of word by word.

My question is: Shouldn't my inline query bring back data only if BOTH fields are matched and not one of them empty?

\\scott\\

On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:

> Again.. I'm not familiar with how inlines in FMP are normally supposed
> to look, but those inlines you've provided look very awkward to me.
> You can use regexp "==" in FMP?
>
> Try taking a look at the other available operators besides "-rx" here:
> http://reference.lassosoft.com/Reference.LassoApp?302
>
> I believe you may be able to use -eq, 'password'=$password instead of
> -rx, 'password' = '=="' + $password + '"'
>
> Izz
>
>
>
> On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:
>> I've put this into my display page and it works now.
>>
>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>> [Inline:
>> -Database='registration-eight',
>> -table='table',
>> -rx,
>> 'username' = '=="'+$username+'"',
>> -rx,
>> 'password' = '=="'+$password+'"',
>> -username='search',
>> -password='xxxxxxx',
>> -search]
>>
>> [If: (Error_CurrentError) != (Error_NoError)]An error has occurred. ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>> [if: ($password)->size < 1]
>>
>>        Please enter a password!
>>
>>        [else]
>>
>> [if: ($username)->size < 1]
>>
>>        Please enter a username!
>>
>>        [else]
>>
>> [If: (Found_Count) == 1]
>>
>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>
>>        [else]
>>
>> Sorry! Wrong password!
>>
>> [/If]
>> [/If]
>> [/If]
>> [/inline]
>>
>> So i guess I'm just wondering: isn't my inline supposed to only return exact matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?
>>
>>
>> On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>
>>> Hi all,
>>>
>>> I have a strange issue with username and passwords on two different Filemaker db's.
>>>
>>> They are each set up the same in FM and in Lasso and are using the same lasso code.
>>>
>>> However with one of the db's it works as it should:  It only returns data when a username and password are entered.
>>>
>>> On the other db, it will return data when the password field is blank!
>>> It will also return null if I type in the incorrect password.
>>>
>>> Here's my lasso code for the display data page:
>>>
>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>> [Inline:
>>> -Database='reg-8',
>>> -table='table',
>>> -rx,
>>> 'username' = '=="'+$username+'"',
>>> -rx,
>>> 'password' = '=="'+$password+'"',
>>> -username='search',
>>> -password='xxxxxx',
>>> -keyvalue=KeyField_Value,
>>> -search]
>>>
>>> If: (Found_Count) == 1]
>>>
>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>
>>> [Else]
>>> Sorry! Wrong password!
>>> [/If]
>>> [/inline]
>>>
>>> I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.
>>>
>>> I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>>>
>>> Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?
>>>
>>> \\scott\\
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

Brian Loomis-3
[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
[Inline:
-Database='registration-eight',
-table='table',
operatorlogical='AND',
-op='eq'
'username' = '=="'+$username+'"',
-op='eq'
'password' = '=="'+$password+'"',
-username='lassositeuser',
-password='lassositeuserpassword',
-maxrecords=1,
-search]


On Oct 28, 2010, at 2:55 PM, Scott Yoshinaga wrote:

> Hi Izz,
>
> I'm using what Steve Piercy suggested in his Oct 13 email.
>
> The -RX operator passes raw FM search expressions as a query.
> For usernames and password, he suggested using "==" to match the entire field instead of word by word.
>
> My question is: Shouldn't my inline query bring back data only if BOTH fields are matched and not one of them empty?
>
> \\scott\\
>
> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>
>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>> to look, but those inlines you've provided look very awkward to me.
>> You can use regexp "==" in FMP?
>>
>> Try taking a look at the other available operators besides "-rx" here:
>> http://reference.lassosoft.com/Reference.LassoApp?302
>>
>> I believe you may be able to use -eq, 'password'=$password instead of
>> -rx, 'password' = '=="' + $password + '"'
>>
>> Izz
>>
>>
>>
>> On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:
>>> I've put this into my display page and it works now.
>>>
>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>> [Inline:
>>> -Database='registration-eight',
>>> -table='table',
>>> -rx,
>>> 'username' = '=="'+$username+'"',
>>> -rx,
>>> 'password' = '=="'+$password+'"',
>>> -username='search',
>>> -password='xxxxxxx',
>>> -search]
>>>
>>> [If: (Error_CurrentError) != (Error_NoError)]An error has occurred. ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>> [if: ($password)->size < 1]
>>>
>>>      Please enter a password!
>>>
>>>      [else]
>>>
>>> [if: ($username)->size < 1]
>>>
>>>      Please enter a username!
>>>
>>>      [else]
>>>
>>> [If: (Found_Count) == 1]
>>>
>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>
>>>      [else]
>>>
>>> Sorry! Wrong password!
>>>
>>> [/If]
>>> [/If]
>>> [/If]
>>> [/inline]
>>>
>>> So i guess I'm just wondering: isn't my inline supposed to only return exact matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?
>>>
>>>
>>> On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>
>>>> Hi all,
>>>>
>>>> I have a strange issue with username and passwords on two different Filemaker db's.
>>>>
>>>> They are each set up the same in FM and in Lasso and are using the same lasso code.
>>>>
>>>> However with one of the db's it works as it should:  It only returns data when a username and password are entered.
>>>>
>>>> On the other db, it will return data when the password field is blank!
>>>> It will also return null if I type in the incorrect password.
>>>>
>>>> Here's my lasso code for the display data page:
>>>>
>>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>>> [Inline:
>>>> -Database='reg-8',
>>>> -table='table',
>>>> -rx,
>>>> 'username' = '=="'+$username+'"',
>>>> -rx,
>>>> 'password' = '=="'+$password+'"',
>>>> -username='search',
>>>> -password='xxxxxx',
>>>> -keyvalue=KeyField_Value,
>>>> -search]
>>>>
>>>> If: (Found_Count) == 1]
>>>>
>>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>
>>>> [Else]
>>>> Sorry! Wrong password!
>>>> [/If]
>>>> [/inline]
>>>>
>>>> I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.
>>>>
>>>> I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>>>>
>>>> Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?
>>>>
>>>> \\scott\\
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>> the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
> the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

Israel Thompson
In reply to this post by kimonostereo
Steve says the rx looks right. And by default the inline should imply
-operatorlogical='AND'... Can you test this query directly in the FMP
database?

Izz


On Thu, Oct 28, 2010 at 3:55 PM, Scott Yoshinaga <[hidden email]> wrote:

> Hi Izz,
>
> I'm using what Steve Piercy suggested in his Oct 13 email.
>
> The -RX operator passes raw FM search expressions as a query.
> For usernames and password, he suggested using "==" to match the entire field instead of word by word.
>
> My question is: Shouldn't my inline query bring back data only if BOTH fields are matched and not one of them empty?
>
> \\scott\\
>
> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>
>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>> to look, but those inlines you've provided look very awkward to me.
>> You can use regexp "==" in FMP?
>>
>> Try taking a look at the other available operators besides "-rx" here:
>> http://reference.lassosoft.com/Reference.LassoApp?302
>>
>> I believe you may be able to use -eq, 'password'=$password instead of
>> -rx, 'password' = '=="' + $password + '"'
>>
>> Izz
>>
>>
>>
>> On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:
>>> I've put this into my display page and it works now.
>>>
>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>> [Inline:
>>> -Database='registration-eight',
>>> -table='table',
>>> -rx,
>>> 'username' = '=="'+$username+'"',
>>> -rx,
>>> 'password' = '=="'+$password+'"',
>>> -username='search',
>>> -password='xxxxxxx',
>>> -search]
>>>
>>> [If: (Error_CurrentError) != (Error_NoError)]An error has occurred. ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>> [if: ($password)->size < 1]
>>>
>>>        Please enter a password!
>>>
>>>        [else]
>>>
>>> [if: ($username)->size < 1]
>>>
>>>        Please enter a username!
>>>
>>>        [else]
>>>
>>> [If: (Found_Count) == 1]
>>>
>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>
>>>        [else]
>>>
>>> Sorry! Wrong password!
>>>
>>> [/If]
>>> [/If]
>>> [/If]
>>> [/inline]
>>>
>>> So i guess I'm just wondering: isn't my inline supposed to only return exact matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?
>>>
>>>
>>> On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>
>>>> Hi all,
>>>>
>>>> I have a strange issue with username and passwords on two different Filemaker db's.
>>>>
>>>> They are each set up the same in FM and in Lasso and are using the same lasso code.
>>>>
>>>> However with one of the db's it works as it should:  It only returns data when a username and password are entered.
>>>>
>>>> On the other db, it will return data when the password field is blank!
>>>> It will also return null if I type in the incorrect password.
>>>>
>>>> Here's my lasso code for the display data page:
>>>>
>>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>>> [Inline:
>>>> -Database='reg-8',
>>>> -table='table',
>>>> -rx,
>>>> 'username' = '=="'+$username+'"',
>>>> -rx,
>>>> 'password' = '=="'+$password+'"',
>>>> -username='search',
>>>> -password='xxxxxx',
>>>> -keyvalue=KeyField_Value,
>>>> -search]
>>>>
>>>> If: (Found_Count) == 1]
>>>>
>>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>
>>>> [Else]
>>>> Sorry! Wrong password!
>>>> [/If]
>>>> [/inline]
>>>>
>>>> I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.
>>>>
>>>> I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>>>>
>>>> Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?
>>>>
>>>> \\scott\\
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>>  the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

Israel Thompson
"he should also check action_statement to see what Lasso sends to FM
http://old.nabble.com/Odd-error-from-a-form...-to28745661.html#a29957031"

"and he should not pass '' into an inline
it's not valid
he should validate the action_param('password') != '' first"

Izz

On Thu, Oct 28, 2010 at 4:19 PM, Israel Thompson
<[hidden email]> wrote:

> Steve says the rx looks right. And by default the inline should imply
> -operatorlogical='AND'... Can you test this query directly in the FMP
> database?
>
> Izz
>
>
> On Thu, Oct 28, 2010 at 3:55 PM, Scott Yoshinaga <[hidden email]> wrote:
>> Hi Izz,
>>
>> I'm using what Steve Piercy suggested in his Oct 13 email.
>>
>> The -RX operator passes raw FM search expressions as a query.
>> For usernames and password, he suggested using "==" to match the entire field instead of word by word.
>>
>> My question is: Shouldn't my inline query bring back data only if BOTH fields are matched and not one of them empty?
>>
>> \\scott\\
>>
>> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>>
>>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>>> to look, but those inlines you've provided look very awkward to me.
>>> You can use regexp "==" in FMP?
>>>
>>> Try taking a look at the other available operators besides "-rx" here:
>>> http://reference.lassosoft.com/Reference.LassoApp?302
>>>
>>> I believe you may be able to use -eq, 'password'=$password instead of
>>> -rx, 'password' = '=="' + $password + '"'
>>>
>>> Izz
>>>
>>>
>>>
>>> On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:
>>>> I've put this into my display page and it works now.
>>>>
>>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>>> [Inline:
>>>> -Database='registration-eight',
>>>> -table='table',
>>>> -rx,
>>>> 'username' = '=="'+$username+'"',
>>>> -rx,
>>>> 'password' = '=="'+$password+'"',
>>>> -username='search',
>>>> -password='xxxxxxx',
>>>> -search]
>>>>
>>>> [If: (Error_CurrentError) != (Error_NoError)]An error has occurred. ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>>> [if: ($password)->size < 1]
>>>>
>>>>        Please enter a password!
>>>>
>>>>        [else]
>>>>
>>>> [if: ($username)->size < 1]
>>>>
>>>>        Please enter a username!
>>>>
>>>>        [else]
>>>>
>>>> [If: (Found_Count) == 1]
>>>>
>>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>
>>>>        [else]
>>>>
>>>> Sorry! Wrong password!
>>>>
>>>> [/If]
>>>> [/If]
>>>> [/If]
>>>> [/inline]
>>>>
>>>> So i guess I'm just wondering: isn't my inline supposed to only return exact matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?
>>>>
>>>>
>>>> On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>>
>>>>> Hi all,
>>>>>
>>>>> I have a strange issue with username and passwords on two different Filemaker db's.
>>>>>
>>>>> They are each set up the same in FM and in Lasso and are using the same lasso code.
>>>>>
>>>>> However with one of the db's it works as it should:  It only returns data when a username and password are entered.
>>>>>
>>>>> On the other db, it will return data when the password field is blank!
>>>>> It will also return null if I type in the incorrect password.
>>>>>
>>>>> Here's my lasso code for the display data page:
>>>>>
>>>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>>>> [Inline:
>>>>> -Database='reg-8',
>>>>> -table='table',
>>>>> -rx,
>>>>> 'username' = '=="'+$username+'"',
>>>>> -rx,
>>>>> 'password' = '=="'+$password+'"',
>>>>> -username='search',
>>>>> -password='xxxxxx',
>>>>> -keyvalue=KeyField_Value,
>>>>> -search]
>>>>>
>>>>> If: (Found_Count) == 1]
>>>>>
>>>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>
>>>>> [Else]
>>>>> Sorry! Wrong password!
>>>>> [/If]
>>>>> [/inline]
>>>>>
>>>>> I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.
>>>>>
>>>>> I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>>>>>
>>>>> Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?
>>>>>
>>>>> \\scott\\
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>>  the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>>  the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

stevepiercy
In reply to this post by Brian Loomis-3
Do not use -maxrecords because that will return only the first
match of possibly many. If you find more than one record, then
you need to catch that and return an appropriate debugging message.

--steve


On 10/28/10 at 3:15 PM, [hidden email] (Brian Loomis) pronounced:

>[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>[Inline: -Database='registration-eight',
>-table='table', operatorlogical='AND',
>-op='eq'
>'username' = '=="'+$username+'"',
>-op='eq'
>'password' = '=="'+$password+'"', -username='lassositeuser',
>-password='lassositeuserpassword',
>-maxrecords=1,
>-search]
>
>On Oct 28, 2010, at 2:55 PM, Scott Yoshinaga wrote:
>
>>Hi Izz,
>>
>>I'm using what Steve Piercy suggested in his Oct 13 email.
>>The -RX operator passes raw FM search expressions as a query.
>>For usernames and password, he suggested using "==" to match the entire field
>instead of word by word.
>>
>>My question is: Shouldn't my inline query bring back data only if BOTH fields are
>matched and not one of them empty?
>>
>>\\scott\\
>>
>>On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>>
>>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>>> to look, but those inlines you've provided look very awkward to me.
>>> You can use regexp "==" in FMP?
>>>   Try taking a look at the other available operators besides
>>>"-rx" here:
>>> http://reference.lassosoft.com/Reference.LassoApp?302
>>>   I believe you may be able to use -eq, 'password'=$password
>>>instead of
>>> -rx, 'password' = '=="' + $password + '"'
>>>   Izz
>>>     On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga
>>><[hidden email]> wrote:
>>>> I've put this into my display page and it works now.
>>>>   [var:'username'=(action_param: 'username'), 'password'=(action_param:
>'password')]
>>>> [Inline:
>>>> -Database='registration-eight',
>>>> -table='table',
>>>> -rx,
>>>> 'username' = '=="'+$username+'"',
>>>> -rx,
>>>> 'password' = '=="'+$password+'"',
>>>> -username='search',
>>>> -password='xxxxxxx',
>>>> -search]
>>>>   [If: (Error_CurrentError) != (Error_NoError)]An error has occurred.
>([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>>> [if: ($password)->size < 1]
>>>>        Please enter a password!
>>>>        [else]
>>>>   [if: ($username)->size < 1]
>>>>        Please enter a username!
>>>>        [else]
>>>>   [If: (Found_Count) == 1]
>>>>   Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>        [else]
>>>>   Sorry! Wrong password!
>>>>   [/If]
>>>> [/If]
>>>> [/If]
>>>> [/inline]
>>>>   So i guess I'm just wondering: isn't my inline supposed
>>>>to only return exact
>matches of what is in the field when I'm using '=='? Does it
>still return data even if the field is left blank? Is that
>correct behavior?
>>>>    On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>>
>>>>> Hi all,
>>>>>   I have a strange issue with username and passwords on
>>>>>two different Filemaker
>db's.
>>>>>   They are each set up the same in FM and in Lasso and are
>>>>>using the same lasso
>code.
>>>>>   However with one of the db's it works as it should:  It
>>>>>only returns data when a
>username and password are entered.
>>>>>   On the other db, it will return data when the password
>>>>>field is blank!
>>>>> It will also return null if I type in the incorrect password.
>>>>>   Here's my lasso code for the display data page:
>>>>>   [var:'username'=(action_param: 'username'), 'password'=(action_param:
>'password')]
>>>>> [Inline:
>>>>> -Database='reg-8',
>>>>> -table='table',
>>>>> -rx,
>>>>> 'username' = '=="'+$username+'"',
>>>>> -rx,
>>>>> 'password' = '=="'+$password+'"',
>>>>> -username='search',
>>>>> -password='xxxxxx',
>>>>> -keyvalue=KeyField_Value,
>>>>> -search]
>>>>>   If: (Found_Count) == 1]
>>>>>   Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>   [Else]
>>>>> Sorry! Wrong password!
>>>>> [/If]
>>>>> [/inline]
>>>>>   I've double checked all my field settings in FM as well
>>>>>as my settings in lasso
>and they are both correct.
>>>>>   I've also tried changing the database from the broken
>>>>>one to one that works in
>my lasso code to do a reality check and my code works with the
>second db correctly but not the first. I'm guessing that it
>must be a lasso setting or a db setting that I'm not doing, but
>I can't figure out what.
>>>>>   Any ideas why it works correctly on one but not the
>>>>>other? How can I trouble
>shoot this further?
>>>>>   \\scott\\
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>    #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>  
>>>   #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>
>>#############################################################
>>This message is sent to you because you are subscribed to
>>the mailing list <[hidden email]>.
>>To unsubscribe, E-mail to: <[hidden email]>
>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>Send administrative queries to  <[hidden email]>
>>
>
>
>#############################################################
>This message is sent to you because you are subscribed to
>the mailing list <[hidden email]>.
>To unsubscribe, E-mail to: <[hidden email]>
>To switch to the DIGEST mode, E-mail to <[hidden email]>
>To switch to the INDEX mode, E-mail to <[hidden email]>
>Send administrative queries to  <[hidden email]>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

Brian Loomis-3
That's true

You should trap for that.

On Oct 28, 2010, at 3:25 PM, Steve Piercy - Web Site Builder wrote:

> Do not use -maxrecords because that will return only the first match of possibly many. If you find more than one record, then you need to catch that and return an appropriate debugging message.
>
> --steve
>
>
> On 10/28/10 at 3:15 PM, [hidden email] (Brian Loomis) pronounced:
>
>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>> [Inline: -Database='registration-eight',
>> -table='table', operatorlogical='AND',
>> -op='eq'
>> 'username' = '=="'+$username+'"',
>> -op='eq'
>> 'password' = '=="'+$password+'"', -username='lassositeuser',
>> -password='lassositeuserpassword',
>> -maxrecords=1,
>> -search]
>>
>> On Oct 28, 2010, at 2:55 PM, Scott Yoshinaga wrote:
>>
>>> Hi Izz,
>>>
>>> I'm using what Steve Piercy suggested in his Oct 13 email.
>>> The -RX operator passes raw FM search expressions as a query.
>>> For usernames and password, he suggested using "==" to match the entire field
>> instead of word by word.
>>>
>>> My question is: Shouldn't my inline query bring back data only if BOTH fields are
>> matched and not one of them empty?
>>>
>>> \\scott\\
>>>
>>> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>>>
>>>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>>>> to look, but those inlines you've provided look very awkward to me.
>>>> You can use regexp "==" in FMP?
>>>>  Try taking a look at the other available operators besides "-rx" here:
>>>> http://reference.lassosoft.com/Reference.LassoApp?302
>>>>  I believe you may be able to use -eq, 'password'=$password instead of
>>>> -rx, 'password' = '=="' + $password + '"'
>>>>  Izz
>>>>    On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:
>>>>> I've put this into my display page and it works now.
>>>>>  [var:'username'=(action_param: 'username'), 'password'=(action_param:
>> 'password')]
>>>>> [Inline:
>>>>> -Database='registration-eight',
>>>>> -table='table',
>>>>> -rx,
>>>>> 'username' = '=="'+$username+'"',
>>>>> -rx,
>>>>> 'password' = '=="'+$password+'"',
>>>>> -username='search',
>>>>> -password='xxxxxxx',
>>>>> -search]
>>>>>  [If: (Error_CurrentError) != (Error_NoError)]An error has occurred.
>> ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>>>> [if: ($password)->size < 1]
>>>>>       Please enter a password!
>>>>>       [else]
>>>>>  [if: ($username)->size < 1]
>>>>>       Please enter a username!
>>>>>       [else]
>>>>>  [If: (Found_Count) == 1]
>>>>>  Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>       [else]
>>>>>  Sorry! Wrong password!
>>>>>  [/If]
>>>>> [/If]
>>>>> [/If]
>>>>> [/inline]
>>>>>  So i guess I'm just wondering: isn't my inline supposed to only return exact
>> matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?
>>>>>   On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>>>
>>>>>> Hi all,
>>>>>>  I have a strange issue with username and passwords on two different Filemaker
>> db's.
>>>>>>  They are each set up the same in FM and in Lasso and are using the same lasso
>> code.
>>>>>>  However with one of the db's it works as it should:  It only returns data when a
>> username and password are entered.
>>>>>>  On the other db, it will return data when the password field is blank!
>>>>>> It will also return null if I type in the incorrect password.
>>>>>>  Here's my lasso code for the display data page:
>>>>>>  [var:'username'=(action_param: 'username'), 'password'=(action_param:
>> 'password')]
>>>>>> [Inline:
>>>>>> -Database='reg-8',
>>>>>> -table='table',
>>>>>> -rx,
>>>>>> 'username' = '=="'+$username+'"',
>>>>>> -rx,
>>>>>> 'password' = '=="'+$password+'"',
>>>>>> -username='search',
>>>>>> -password='xxxxxx',
>>>>>> -keyvalue=KeyField_Value,
>>>>>> -search]
>>>>>>  If: (Found_Count) == 1]
>>>>>>  Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>>  [Else]
>>>>>> Sorry! Wrong password!
>>>>>> [/If]
>>>>>> [/inline]
>>>>>>  I've double checked all my field settings in FM as well as my settings in lasso
>> and they are both correct.
>>>>>>  I've also tried changing the database from the broken one to one that works in
>> my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>>>>>>  Any ideas why it works correctly on one but not the other? How can I trouble
>> shoot this further?
>>>>>>  \\scott\\
>>>>>> #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>> the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>
>>>>>   #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>  #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>> the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> Steve Piercy               Web Site Builder               Soquel, CA
> <[hidden email]>                  <http://www.StevePiercy.com/>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
> the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

stevepiercy
In reply to this post by kimonostereo
Here's the link:
http://old.nabble.com/Odd-error-from-a-form...-to28745661.html#a29957031

at the end of it:

    Compare the action_statement for each tweak you make to confirm
    that it does what you want.  Also do the search in the FM Pro
    client directly to verify results.

and you should validate user input before it ever gets sent to the inline:

if(action_param('username') == '' || action_param('password') == '');
    // bzzzt!
    'invalid entry';
else(more validation rules);
    // more validation rules
else;
    // OK, *now* search
    inline ...
/if;

--steve

On 10/28/10 at 10:55 AM, [hidden email] (Scott Yoshinaga) pronounced:

> Hi Izz,
>
> I'm using what Steve Piercy suggested in his Oct 13 email.
>
> The -RX operator passes raw FM search expressions as a query.
> For usernames and password, he suggested using "==" to match the entire field instead
> of word by word.
>
> My question is: Shouldn't my inline query bring back data only if BOTH fields are
> matched and not one of them empty?
>
> \\scott\\
>
> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>
> > Again.. I'm not familiar with how inlines in FMP are normally supposed
> > to look, but those inlines you've provided look very awkward to me.
> > You can use regexp "==" in FMP?
> >
> > Try taking a look at the other available operators besides "-rx" here:
> > http://reference.lassosoft.com/Reference.LassoApp?302
> >
> > I believe you may be able to use -eq, 'password'=$password instead of
> > -rx, 'password' = '=="' + $password + '"'
> >
> > Izz
> >
> >
> >
> > On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:
> >> I've put this into my display page and it works now.
> >>
> >> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
> >> [Inline:
> >> -Database='registration-eight',
> >> -table='table',
> >> -rx,
> >> 'username' = '=="'+$username+'"',
> >> -rx,
> >> 'password' = '=="'+$password+'"',
> >> -username='search',
> >> -password='xxxxxxx',
> >> -search]
> >>
> >> [If: (Error_CurrentError) != (Error_NoError)]An error has occurred.
> ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
> >> [if: ($password)->size < 1]
> >>
> >>        Please enter a password!
> >>
> >>        [else]
> >>
> >> [if: ($username)->size < 1]
> >>
> >>        Please enter a username!
> >>
> >>        [else]
> >>
> >> [If: (Found_Count) == 1]
> >>
> >> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
> >>
> >>        [else]
> >>
> >> Sorry! Wrong password!
> >>
> >> [/If]
> >> [/If]
> >> [/If]
> >> [/inline]
> >>
> >> So i guess I'm just wondering: isn't my inline supposed to only return exact
> matches of what is in the field when I'm using '=='? Does it still return data even
> if the field is left blank? Is that correct behavior?
> >>
> >>
> >> On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
> >>
> >>> Hi all,
> >>>
> >>> I have a strange issue with username and passwords on two different Filemaker
> db's.
> >>>
> >>> They are each set up the same in FM and in Lasso and are using the same lasso
> code.
> >>>
> >>> However with one of the db's it works as it should:  It only returns data when a
> username and password are entered.
> >>>
> >>> On the other db, it will return data when the password field is blank!
> >>> It will also return null if I type in the incorrect password.
> >>>
> >>> Here's my lasso code for the display data page:
> >>>
> >>> [var:'username'=(action_param: 'username'), 'password'=(action_param:
> 'password')]
> >>> [Inline:
> >>> -Database='reg-8',
> >>> -table='table',
> >>> -rx,
> >>> 'username' = '=="'+$username+'"',
> >>> -rx,
> >>> 'password' = '=="'+$password+'"',
> >>> -username='search',
> >>> -password='xxxxxx',
> >>> -keyvalue=KeyField_Value,
> >>> -search]
> >>>
> >>> If: (Found_Count) == 1]
> >>>
> >>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
> >>>
> >>> [Else]
> >>> Sorry! Wrong password!
> >>> [/If]
> >>> [/inline]
> >>>
> >>> I've double checked all my field settings in FM as well as my settings in lasso
> and they are both correct.
> >>>
> >>> I've also tried changing the database from the broken one to one that works in my
> lasso code to do a reality check and my code works with the second db correctly but
> not the first. I'm guessing that it must be a lasso setting or a db setting that I'm
> not doing, but I can't figure out what.
> >>>
> >>> Any ideas why it works correctly on one but not the other? How can I trouble
> shoot this further?
> >>>
> >>> \\scott\\
> >>> #############################################################
> >>> This message is sent to you because you are subscribed to
> >>>  the mailing list <[hidden email]>.
> >>> To unsubscribe, E-mail to: <[hidden email]>
> >>> To switch to the DIGEST mode, E-mail to <[hidden email]>
> >>> To switch to the INDEX mode, E-mail to <[hidden email]>
> >>> Send administrative queries to  <[hidden email]>
> >>>
> >>
> >>
> >> #############################################################
> >> This message is sent to you because you are subscribed to
> >>  the mailing list <[hidden email]>.
> >> To unsubscribe, E-mail to: <[hidden email]>
> >> To switch to the DIGEST mode, E-mail to <[hidden email]>
> >> To switch to the INDEX mode, E-mail to <[hidden email]>
> >> Send administrative queries to  <[hidden email]>
> >>
> >>
> >
> > #############################################################
> > This message is sent to you because you are subscribed to
> >  the mailing list <[hidden email]>.
> > To unsubscribe, E-mail to: <[hidden email]>
> > To switch to the DIGEST mode, E-mail to <[hidden email]>
> > To switch to the INDEX mode, E-mail to <[hidden email]>
> > Send administrative queries to  <[hidden email]>
> >
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>   the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
Steve Piercy               Web Site Builder               Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

Johan Solve
In reply to this post by stevepiercy
Actully, found_count would report a number larger than 1 even with
-maxrecords=1 so you can trap for multiple matches anyway.

On Thu, Oct 28, 2010 at 11:25 PM, Steve Piercy - Web Site Builder
<[hidden email]> wrote:

> Do not use -maxrecords because that will return only the first match of
> possibly many. If you find more than one record, then you need to catch that
> and return an appropriate debugging message.
>
> --steve
>
>
> On 10/28/10 at 3:15 PM, [hidden email] (Brian Loomis) pronounced:
>
>> [var:'username'=(action_param: 'username'), 'password'=(action_param:
>> 'password')]
>> [Inline: -Database='registration-eight',
>> -table='table', operatorlogical='AND',
>> -op='eq'
>> 'username' = '=="'+$username+'"',
>> -op='eq'
>> 'password' = '=="'+$password+'"', -username='lassositeuser',
>> -password='lassositeuserpassword',
>> -maxrecords=1,
>> -search]
>>
>> On Oct 28, 2010, at 2:55 PM, Scott Yoshinaga wrote:
>>
>>> Hi Izz,
>>>
>>> I'm using what Steve Piercy suggested in his Oct 13 email.
>>> The -RX operator passes raw FM search expressions as a query.
>>> For usernames and password, he suggested using "==" to match the entire
>>> field
>>
>> instead of word by word.
>>>
>>> My question is: Shouldn't my inline query bring back data only if BOTH
>>> fields are
>>
>> matched and not one of them empty?
>>>
>>> \\scott\\
>>>
>>> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>>>
>>>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>>>> to look, but those inlines you've provided look very awkward to me.
>>>> You can use regexp "==" in FMP?
>>>>  Try taking a look at the other available operators besides "-rx" here:
>>>> http://reference.lassosoft.com/Reference.LassoApp?302
>>>>  I believe you may be able to use -eq, 'password'=$password instead of
>>>> -rx, 'password' = '=="' + $password + '"'
>>>>  Izz
>>>>    On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]>
>>>> wrote:
>>>>>
>>>>> I've put this into my display page and it works now.
>>>>>  [var:'username'=(action_param: 'username'), 'password'=(action_param:
>>
>> 'password')]
>>>>>
>>>>> [Inline:
>>>>> -Database='registration-eight',
>>>>> -table='table',
>>>>> -rx,
>>>>> 'username' = '=="'+$username+'"',
>>>>> -rx,
>>>>> 'password' = '=="'+$password+'"',
>>>>> -username='search',
>>>>> -password='xxxxxxx',
>>>>> -search]
>>>>>  [If: (Error_CurrentError) != (Error_NoError)]An error has occurred.
>>
>> ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>>>>
>>>>> [if: ($password)->size < 1]
>>>>>       Please enter a password!
>>>>>       [else]
>>>>>  [if: ($username)->size < 1]
>>>>>       Please enter a username!
>>>>>       [else]
>>>>>  [If: (Found_Count) == 1]
>>>>>  Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>       [else]
>>>>>  Sorry! Wrong password!
>>>>>  [/If]
>>>>> [/If]
>>>>> [/If]
>>>>> [/inline]
>>>>>  So i guess I'm just wondering: isn't my inline supposed to only return
>>>>> exact
>>
>> matches of what is in the field when I'm using '=='? Does it still return
>> data even if the field is left blank? Is that correct behavior?
>>>>>
>>>>>   On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>>>
>>>>>> Hi all,
>>>>>>  I have a strange issue with username and passwords on two different
>>>>>> Filemaker
>>
>> db's.
>>>>>>
>>>>>>  They are each set up the same in FM and in Lasso and are using the
>>>>>> same lasso
>>
>> code.
>>>>>>
>>>>>>  However with one of the db's it works as it should:  It only returns
>>>>>> data when a
>>
>> username and password are entered.
>>>>>>
>>>>>>  On the other db, it will return data when the password field is
>>>>>> blank!
>>>>>> It will also return null if I type in the incorrect password.
>>>>>>  Here's my lasso code for the display data page:
>>>>>>  [var:'username'=(action_param: 'username'), 'password'=(action_param:
>>
>> 'password')]
>>>>>>
>>>>>> [Inline:
>>>>>> -Database='reg-8',
>>>>>> -table='table',
>>>>>> -rx,
>>>>>> 'username' = '=="'+$username+'"',
>>>>>> -rx,
>>>>>> 'password' = '=="'+$password+'"',
>>>>>> -username='search',
>>>>>> -password='xxxxxx',
>>>>>> -keyvalue=KeyField_Value,
>>>>>> -search]
>>>>>>  If: (Found_Count) == 1]
>>>>>>  Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>>  [Else]
>>>>>> Sorry! Wrong password!
>>>>>> [/If]
>>>>>> [/inline]
>>>>>>  I've double checked all my field settings in FM as well as my
>>>>>> settings in lasso
>>
>> and they are both correct.
>>>>>>
>>>>>>  I've also tried changing the database from the broken one to one that
>>>>>> works in
>>
>> my lasso code to do a reality check and my code works with the second db
>> correctly but not the first. I'm guessing that it must be a lasso setting or
>> a db setting that I'm not doing, but I can't figure out what.
>>>>>>
>>>>>>  Any ideas why it works correctly on one but not the other? How can I
>>>>>> trouble
>>
>> shoot this further?
>>>>>>
>>>>>>  \\scott\\
>>>>>> #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>> the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>
>>>>>   #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to
>>>>> <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to
>>>>> <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>
>>>>  #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to
>>> <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>> the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> Steve Piercy               Web Site Builder               Soquel, CA
> <[hidden email]>                  <http://www.StevePiercy.com/>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>



--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

kimonostereo
In reply to this post by Brian Loomis-3
Hi Brian, Izz and Steven,

You have operatorlogical='And' in there, but according to Lasso 8.5 language guide, FM defaults to 'and', so I wonder if it's necessary?

I did try your suggestion but it didn't work:
[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
[Inline:
-Database='registration-eight',
-table='table',
operatorlogical='AND',
-op='eq'
'username' = '=="'+$username+'"',
-op='eq'
'password' = '=="'+$password+'"',
-username='lassositeuser',
-password='lassositeuserpassword',
-maxrecords=1,
-search]


In fact I am wondering if there is something wrong with Lasso because the only way I could get it to work correctly is to use this:

[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
[Inline:
-Database='registration-eight',
-table='table',
'username' = '="'+$username+'"',
'password' = '="'+$password+'"',
-username='search',
-password='xxxxxxx*',
-search]

It seems like when I use -eq and '==' together, Lasso seems to be ignoring it.

If I use '==' with -rx it works but ignores the search for password if I leave it blank and returns data anyway.

I've tested the operators in my FM Pro 10 databases and it works fine, it just doesn't seem to work with Lasso for some reason?

\\scott\\


On Oct 28, 2010, at 11:15 AM, Brian Loomis wrote:

> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
> [Inline:
> -Database='registration-eight',
> -table='table',
> operatorlogical='AND',
> -op='eq'
> 'username' = '=="'+$username+'"',
> -op='eq'
> 'password' = '=="'+$password+'"',
> -username='lassositeuser',
> -password='lassositeuserpassword',
> -maxrecords=1,
> -search]
>
>
> On Oct 28, 2010, at 2:55 PM, Scott Yoshinaga wrote:
>
>> Hi Izz,
>>
>> I'm using what Steve Piercy suggested in his Oct 13 email.
>>
>> The -RX operator passes raw FM search expressions as a query.
>> For usernames and password, he suggested using "==" to match the entire field instead of word by word.
>>
>> My question is: Shouldn't my inline query bring back data only if BOTH fields are matched and not one of them empty?
>>
>> \\scott\\
>>
>> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>>
>>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>>> to look, but those inlines you've provided look very awkward to me.
>>> You can use regexp "==" in FMP?
>>>
>>> Try taking a look at the other available operators besides "-rx" here:
>>> http://reference.lassosoft.com/Reference.LassoApp?302
>>>
>>> I believe you may be able to use -eq, 'password'=$password instead of
>>> -rx, 'password' = '=="' + $password + '"'
>>>
>>> Izz
>>>
>>>
>>>
>>> On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]> wrote:
>>>> I've put this into my display page and it works now.
>>>>
>>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>>> [Inline:
>>>> -Database='registration-eight',
>>>> -table='table',
>>>> -rx,
>>>> 'username' = '=="'+$username+'"',
>>>> -rx,
>>>> 'password' = '=="'+$password+'"',
>>>> -username='search',
>>>> -password='xxxxxxx',
>>>> -search]
>>>>
>>>> [If: (Error_CurrentError) != (Error_NoError)]An error has occurred. ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>>> [if: ($password)->size < 1]
>>>>
>>>>     Please enter a password!
>>>>
>>>>     [else]
>>>>
>>>> [if: ($username)->size < 1]
>>>>
>>>>     Please enter a username!
>>>>
>>>>     [else]
>>>>
>>>> [If: (Found_Count) == 1]
>>>>
>>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>
>>>>     [else]
>>>>
>>>> Sorry! Wrong password!
>>>>
>>>> [/If]
>>>> [/If]
>>>> [/If]
>>>> [/inline]
>>>>
>>>> So i guess I'm just wondering: isn't my inline supposed to only return exact matches of what is in the field when I'm using '=='? Does it still return data even if the field is left blank? Is that correct behavior?
>>>>
>>>>
>>>> On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>>
>>>>> Hi all,
>>>>>
>>>>> I have a strange issue with username and passwords on two different Filemaker db's.
>>>>>
>>>>> They are each set up the same in FM and in Lasso and are using the same lasso code.
>>>>>
>>>>> However with one of the db's it works as it should:  It only returns data when a username and password are entered.
>>>>>
>>>>> On the other db, it will return data when the password field is blank!
>>>>> It will also return null if I type in the incorrect password.
>>>>>
>>>>> Here's my lasso code for the display data page:
>>>>>
>>>>> [var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>>>> [Inline:
>>>>> -Database='reg-8',
>>>>> -table='table',
>>>>> -rx,
>>>>> 'username' = '=="'+$username+'"',
>>>>> -rx,
>>>>> 'password' = '=="'+$password+'"',
>>>>> -username='search',
>>>>> -password='xxxxxx',
>>>>> -keyvalue=KeyField_Value,
>>>>> -search]
>>>>>
>>>>> If: (Found_Count) == 1]
>>>>>
>>>>> Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>
>>>>> [Else]
>>>>> Sorry! Wrong password!
>>>>> [/If]
>>>>> [/inline]
>>>>>
>>>>> I've double checked all my field settings in FM as well as my settings in lasso and they are both correct.
>>>>>
>>>>> I've also tried changing the database from the broken one to one that works in my lasso code to do a reality check and my code works with the second db correctly but not the first. I'm guessing that it must be a lasso setting or a db setting that I'm not doing, but I can't figure out what.
>>>>>
>>>>> Any ideas why it works correctly on one but not the other? How can I trouble shoot this further?
>>>>>
>>>>> \\scott\\
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>> the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

stevepiercy
In reply to this post by Johan Solve
That's true.  Although if you use -maxrecords and you don't
understand that -maxrecords only returns X records and not the
found_count, then you might not realize what is going on.  It's
a common newbie mistake.

I think the best practice is to leave it off unless you really
need it, and define -maxrecords='all' in the array of connection parameters.

--steve


On 10/29/10 at 12:17 AM, [hidden email] (Johan Solve) pronounced:

>Actully, found_count would report a number larger than 1 even with
>-maxrecords=1 so you can trap for multiple matches anyway.
>
>On Thu, Oct 28, 2010 at 11:25 PM, Steve Piercy - Web Site Builder
><[hidden email]> wrote:
>>Do not use -maxrecords because that will return only the first match of
>>possibly many. If you find more than one record, then you need to catch that
>>and return an appropriate debugging message.
>>
>>--steve
>>
>>
>>On 10/28/10 at 3:15 PM, [hidden email] (Brian Loomis) pronounced:
>>
>>> [var:'username'=(action_param: 'username'), 'password'=(action_param:
>>> 'password')]
>>> [Inline: -Database='registration-eight',
>>> -table='table', operatorlogical='AND',
>>> -op='eq'
>>> 'username' = '=="'+$username+'"',
>>> -op='eq'
>>> 'password' = '=="'+$password+'"', -username='lassositeuser',
>>> -password='lassositeuserpassword',
>>> -maxrecords=1,
>>> -search]
>>>
>>> On Oct 28, 2010, at 2:55 PM, Scott Yoshinaga wrote:
>>>
>>>> Hi Izz,
>>>>
>>>> I'm using what Steve Piercy suggested in his Oct 13 email.
>>>> The -RX operator passes raw FM search expressions as a query.
>>>> For usernames and password, he suggested using "==" to match the entire
>>>> field
>>>
>>> instead of word by word.
>>>>
>>>> My question is: Shouldn't my inline query bring back data only if BOTH
>>>> fields are
>>>
>>> matched and not one of them empty?
>>>>
>>>> \\scott\\
>>>>
>>>> On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>>>>
>>>>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>>>>> to look, but those inlines you've provided look very awkward to me.
>>>>> You can use regexp "==" in FMP?
>>>>>  Try taking a look at the other available operators besides "-rx" here:
>>>>> http://reference.lassosoft.com/Reference.LassoApp?302
>>>>>  I believe you may be able to use -eq, 'password'=$password instead of
>>>>> -rx, 'password' = '=="' + $password + '"'
>>>>>  Izz
>>>>>    On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga <[hidden email]>
>>>>> wrote:
>>>>>>
>>>>>> I've put this into my display page and it works now.
>>>>>>  [var:'username'=(action_param: 'username'), 'password'=(action_param:
>>>
>>> 'password')]
>>>>>>
>>>>>> [Inline:
>>>>>> -Database='registration-eight',
>>>>>> -table='table',
>>>>>> -rx,
>>>>>> 'username' = '=="'+$username+'"',
>>>>>> -rx,
>>>>>> 'password' = '=="'+$password+'"',
>>>>>> -username='search',
>>>>>> -password='xxxxxxx',
>>>>>> -search]
>>>>>>  [If: (Error_CurrentError) != (Error_NoError)]An error has occurred.
>>>
>>> ([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>>>>>
>>>>>> [if: ($password)->size < 1]
>>>>>>       Please enter a password!
>>>>>>       [else]
>>>>>>  [if: ($username)->size < 1]
>>>>>>       Please enter a username!
>>>>>>       [else]
>>>>>>  [If: (Found_Count) == 1]
>>>>>>  Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>>       [else]
>>>>>>  Sorry! Wrong password!
>>>>>>  [/If]
>>>>>> [/If]
>>>>>> [/If]
>>>>>> [/inline]
>>>>>>  So i guess I'm just wondering: isn't my inline supposed to only return
>>>>>> exact
>>>
>>> matches of what is in the field when I'm using '=='? Does it still return
>>> data even if the field is left blank? Is that correct behavior?
>>>>>>
>>>>>>   On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>>>>
>>>>>>> Hi all,
>>>>>>>  I have a strange issue with username and passwords on two different
>>>>>>> Filemaker
>>>
>>> db's.
>>>>>>>
>>>>>>>  They are each set up the same in FM and in Lasso and are using the
>>>>>>> same lasso
>>>
>>> code.
>>>>>>>
>>>>>>>  However with one of the db's it works as it should:  It only returns
>>>>>>> data when a
>>>
>>> username and password are entered.
>>>>>>>
>>>>>>>  On the other db, it will return data when the password field is
>>>>>>> blank!
>>>>>>> It will also return null if I type in the incorrect password.
>>>>>>>  Here's my lasso code for the display data page:
>>>>>>>  [var:'username'=(action_param: 'username'), 'password'=(action_param:
>>>
>>> 'password')]
>>>>>>>
>>>>>>> [Inline:
>>>>>>> -Database='reg-8',
>>>>>>> -table='table',
>>>>>>> -rx,
>>>>>>> 'username' = '=="'+$username+'"',
>>>>>>> -rx,
>>>>>>> 'password' = '=="'+$password+'"',
>>>>>>> -username='search',
>>>>>>> -password='xxxxxx',
>>>>>>> -keyvalue=KeyField_Value,
>>>>>>> -search]
>>>>>>>  If: (Found_Count) == 1]
>>>>>>>  Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>>>  [Else]
>>>>>>> Sorry! Wrong password!
>>>>>>> [/If]
>>>>>>> [/inline]
>>>>>>>  I've double checked all my field settings in FM as well as my
>>>>>>> settings in lasso
>>>
>>> and they are both correct.
>>>>>>>
>>>>>>>  I've also tried changing the database from the broken one to one that
>>>>>>> works in
>>>
>>> my lasso code to do a reality check and my code works with the second db
>>> correctly but not the first. I'm guessing that it must be a lasso setting or
>>> a db setting that I'm not doing, but I can't figure out what.
>>>>>>>
>>>>>>>  Any ideas why it works correctly on one but not the other? How can I
>>>>>>> trouble
>>>
>>> shoot this further?
>>>>>>>
>>>>>>>  \\scott\\
>>>>>>> #############################################################
>>>>>>> This message is sent to you because you are subscribed to
>>>>>>> the mailing list <[hidden email]>.
>>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> To switch to the INDEX mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>>
>>>>>>   #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>> the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>
>>>>>
>>>>>  #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to
>>>>> <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>Steve Piercy               Web Site Builder               Soquel, CA
>><[hidden email]>                  <http://www.StevePiercy.com/>
>>
>>
>>#############################################################
>>This message is sent to you because you are subscribed to
>> the mailing list <[hidden email]>.
>>To unsubscribe, E-mail to: <[hidden email]>
>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>Send administrative queries to  <[hidden email]>
>>
>>
>
>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

stevepiercy
In reply to this post by kimonostereo
On 10/28/10 at 12:36 PM, [hidden email] (Scott Yoshinaga) pronounced:

>Hi Brian, Izz and Steven,
>
>You have operatorlogical='And' in there, but according to Lasso
>8.5 language guide, FM defaults to 'and', so I wonder if it's necessary?

You are correct.  It is not necessary.

>In fact I am wondering if there is something wrong with Lasso
>because the only way I could get it to work correctly is to use this:
>
>[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>[Inline: -Database='registration-eight',
>-table='table',
>'username' = '="'+$username+'"',
>'password' = '="'+$password+'"', -username='search',
>-password='xxxxxxx*',
>-search]
>It seems like when I use -eq and '==' together, Lasso seems to be ignoring it.

That is because -eq and == don't work together, but -rx and == do.

>If I use '==' with -rx it works but ignores the search for
>password if I leave it blank and returns data anyway.

What does action_statement show for each test?

Also as I stated in a separate email, you should *always*
validate user input before you pass it to an inline.  Don't
allow for empty values.

>I've tested the operators in my FM Pro 10 databases and it
>works fine, it just doesn't seem to work with Lasso for some reason?
>
>\\scott\\
>
>
>On Oct 28, 2010, at 11:15 AM, Brian Loomis wrote:
>
>>[var:'username'=(action_param: 'username'), 'password'=(action_param: 'password')]
>>[Inline: -Database='registration-eight',
>>-table='table', operatorlogical='AND',
>>-op='eq'
>>'username' = '=="'+$username+'"',
>>-op='eq'
>>'password' = '=="'+$password+'"', -username='lassositeuser',
>>-password='lassositeuserpassword',
>>-maxrecords=1,
>>-search]
>>
>>On Oct 28, 2010, at 2:55 PM, Scott Yoshinaga wrote:
>>
>>> Hi Izz,
>>>   I'm using what Steve Piercy suggested in his Oct 13
>>>email.   The -RX operator passes raw FM search expressions as
>>>a query.
>>> For usernames and password, he suggested using "==" to match the entire field
>instead of word by word.
>>>   My question is: Shouldn't my inline query bring back data
>>>only if BOTH fields are
>matched and not one of them empty?
>>>   \\scott\\
>>>   On Oct 28, 2010, at 10:28 AM, Israel Thompson wrote:
>>>
>>>> Again.. I'm not familiar with how inlines in FMP are normally supposed
>>>> to look, but those inlines you've provided look very awkward to me.
>>>> You can use regexp "==" in FMP?
>>>>   Try taking a look at the other available operators
>>>>besides "-rx" here:
>>>> http://reference.lassosoft.com/Reference.LassoApp?302
>>>>   I believe you may be able to use -eq,
>>>>'password'=$password instead of
>>>> -rx, 'password' = '=="' + $password + '"'
>>>>   Izz
>>>>     On Thu, Oct 28, 2010 at 3:19 PM, Scott Yoshinaga
>>>><[hidden email]> wrote:
>>>>> I've put this into my display page and it works now.
>>>>>   [var:'username'=(action_param: 'username'), 'password'=(action_param:
>'password')]
>>>>> [Inline:
>>>>> -Database='registration-eight',
>>>>> -table='table',
>>>>> -rx,
>>>>> 'username' = '=="'+$username+'"',
>>>>> -rx,
>>>>> 'password' = '=="'+$password+'"',
>>>>> -username='search',
>>>>> -password='xxxxxxx',
>>>>> -search]
>>>>>   [If: (Error_CurrentError) != (Error_NoError)]An error
>>>>>has occurred.
>([Error_CurrentError: -ErrorCode] [Error_CurrentError])[/If]
>>>>> [if: ($password)->size < 1]
>>>>>       Please enter a password!
>>>>>       [else]
>>>>>   [if: ($username)->size < 1]
>>>>>       Please enter a username!
>>>>>       [else]
>>>>>   [If: (Found_Count) == 1]
>>>>>   Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>       [else]
>>>>>   Sorry! Wrong password!
>>>>>   [/If]
>>>>> [/If]
>>>>> [/If]
>>>>> [/inline]
>>>>>   So i guess I'm just wondering: isn't my inline supposed
>>>>>to only return exact
>matches of what is in the field when I'm using '=='? Does it
>still return data even if the field is left blank? Is that
>correct behavior?
>>>>>    On Oct 28, 2010, at 8:26 AM, Scott Yoshinaga wrote:
>>>>>
>>>>>> Hi all,
>>>>>>   I have a strange issue with username and passwords on
>>>>>>two different Filemaker
>db's.
>>>>>>   They are each set up the same in FM and in Lasso and
>>>>>>are using the same lasso
>code.
>>>>>>   However with one of the db's it works as it should:  It
>>>>>>only returns data when
>a username and password are entered.
>>>>>>   On the other db, it will return data when the password
>>>>>>field is blank!
>>>>>> It will also return null if I type in the incorrect password.
>>>>>>   Here's my lasso code for the display data page:
>>>>>>   [var:'username'=(action_param: 'username'), 'password'=(action_param:
>'password')]
>>>>>> [Inline:
>>>>>> -Database='reg-8',
>>>>>> -table='table',
>>>>>> -rx,
>>>>>> 'username' = '=="'+$username+'"',
>>>>>> -rx,
>>>>>> 'password' = '=="'+$password+'"',
>>>>>> -username='search',
>>>>>> -password='xxxxxx',
>>>>>> -keyvalue=KeyField_Value,
>>>>>> -search]
>>>>>>   If: (Found_Count) == 1]
>>>>>>   Hello [Field: 'student_firstname'] [Field: 'student_lastname']
>>>>>>   [Else]
>>>>>> Sorry! Wrong password!
>>>>>> [/If]
>>>>>> [/inline]
>>>>>>   I've double checked all my field settings in FM as well
>>>>>>as my settings in lasso
>and they are both correct.
>>>>>>   I've also tried changing the database from the broken
>>>>>>one to one that works in
>my lasso code to do a reality check and my code works with the
>second db correctly but not the first. I'm guessing that it
>must be a lasso setting or a db setting that I'm not doing, but
>I can't figure out what.
>>>>>>   Any ideas why it works correctly on one but not the
>>>>>>other? How can I trouble
>shoot this further?
>>>>>>   \\scott\\
>>>>>> #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>> the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>
>>>>>    #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>  
>>>>   #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>    #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>
>>#############################################################
>>This message is sent to you because you are subscribed to
>>the mailing list <[hidden email]>.
>>To unsubscribe, E-mail to: <[hidden email]>
>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>Send administrative queries to  <[hidden email]>
>>
>
>
>#############################################################
>This message is sent to you because you are subscribed to
>the mailing list <[hidden email]>.
>To unsubscribe, E-mail to: <[hidden email]>
>To switch to the DIGEST mode, E-mail to <[hidden email]>
>To switch to the INDEX mode, E-mail to <[hidden email]>
>Send administrative queries to  <[hidden email]>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

jasonhuck
In reply to this post by stevepiercy
> I think the best practice is to leave it off unless you really need it, and define -maxrecords='all' in the array of connection parameters.
>
> --steve


Although, you must remember that it does not propagate to nested inlines like other parameters do.

- jason
#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

stevepiercy
On 10/28/10 at 7:19 PM, [hidden email] (Jason Huck) pronounced:

> > I think the best practice is to leave it off unless you really need it, and define
> > -maxrecords='all' in the array of connection parameters.
> >
> > --steve
>
>
> Although, you must remember that it does not propagate to nested inlines like other
> parameters do.

Actually, I meant like this:

    var('cnxn') = array(
        -database   = 'd',
        -table      = 't',
        -username   = 'u',
        -password   = 'p',
        -maxrecords = 'all',
        -nothing);
   
    inline($cnxn,
        // parameters that override $cnxn parameters
        ...
        -maxrecords = 1,
        -search);
    /inline;

--steve

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
Steve Piercy               Web Site Builder               Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

jasonhuck
Yes, and if you want to pool connections, you won't repeat that connection var in nested inlines. All of the other params will propagate into them automatically, but -maxrecords will not.

Just a reminder!

- jason



On Oct 28, 2010, at 7:37 PM, Steve Piercy - Web Site Builder <[hidden email]> wrote:

> On 10/28/10 at 7:19 PM, [hidden email] (Jason Huck) pronounced:
>
>>> I think the best practice is to leave it off unless you really need it, and define
>>> -maxrecords='all' in the array of connection parameters.
>>>
>>> --steve
>>
>>
>> Although, you must remember that it does not propagate to nested inlines like other
>> parameters do.
>
> Actually, I meant like this:
>
>    var('cnxn') = array(
>        -database   = 'd',
>        -table      = 't',
>        -username   = 'u',
>        -password   = 'p',
>        -maxrecords = 'all',
>        -nothing);
>
>    inline($cnxn,
>        // parameters that override $cnxn parameters
>        ...
>        -maxrecords = 1,
>        -search);
>    /inline;
>
> --steve
>
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> Steve Piercy               Web Site Builder               Soquel, CA
> <[hidden email]>                  <http://www.StevePiercy.com/>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

stevepiercy
But aren't pooled connections broken in 8.5.6?  Or was that via
the -host inline method?  I can't remember off the top of my
head, as I almost always use raw -sql these days:

-sql="statement1; statement2; ... statementN;"

--steve


On 10/28/10 at 8:17 PM, [hidden email] (Jason Huck) pronounced:

>Yes, and if you want to pool connections, you won't repeat that
>connection var in nested inlines. All of the other params will
>propagate into them automatically, but -maxrecords will not.
>
>Just a reminder!
>
>- jason
>
>
>
>On Oct 28, 2010, at 7:37 PM, Steve Piercy - Web Site Builder
><[hidden email]> wrote:
>
>>On 10/28/10 at 7:19 PM, [hidden email] (Jason Huck) pronounced:
>>
>>>> I think the best practice is to leave it off unless you really need it, and
>define
>>>> -maxrecords='all' in the array of connection parameters.
>>>>   --steve
>>>    Although, you must remember that it does not propagate to
>>>nested inlines like
>other
>>> parameters do.
>>
>>Actually, I meant like this:
>>
>>var('cnxn') = array(
>>-database   = 'd',
>>-table      = 't',
>>-username   = 'u',
>>-password   = 'p',
>>-maxrecords = 'all',
>>-nothing);
>>
>>inline($cnxn,
>>// parameters that override $cnxn parameters
>>...
>>-maxrecords = 1,
>>-search);
>>/inline;
>>
>>--steve
>>
>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>Steve Piercy               Web Site Builder               Soquel, CA
>><[hidden email]>                  <http://www.StevePiercy.com/>
>>
>>
>>#############################################################
>>This message is sent to you because you are subscribed to
>>the mailing list <[hidden email]>.
>>To unsubscribe, E-mail to: <[hidden email]>
>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>Send administrative queries to  <[hidden email]>
>>
>
>#############################################################
>This message is sent to you because you are subscribed to
>the mailing list <[hidden email]>.
>To unsubscribe, E-mail to: <[hidden email]>
>To switch to the DIGEST mode, E-mail to <[hidden email]>
>To switch to the INDEX mode, E-mail to <[hidden email]>
>Send administrative queries to  <[hidden email]>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

jasonhuck
On Thu, Oct 28, 2010 at 8:57 PM, Steve Piercy - Web Site Builder
<[hidden email]> wrote:
> But aren't pooled connections broken in 8.5.6?
> Or was that via the -host inline method?

One or the other was, in a previous point release, but IIRC, both work
as advertised in 8.5.6.


> I can't remember off the top of my head, as I almost always
> use raw -sql these days:

The style of inline ("classic" vs. "sql') you use makes no difference
as to whether or not the connections are pooled.

If you're combining all your queries into one single inline and
pulling out the various results with [resultset], you're sidestepping
the issue. Interesting thought, though I think it would be difficult
to stick to in practice.

- jason

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: username / password strangeness

stevepiercy
On 10/28/10 at 9:47 PM, [hidden email] (Jason Huck) pronounced:

>On Thu, Oct 28, 2010 at 8:57 PM, Steve Piercy - Web Site Builder
><[hidden email]> wrote:
>>But aren't pooled connections broken in 8.5.6?
>>Or was that via the -host inline method?
>
>One or the other was, in a previous point release, but IIRC, both work
>as advertised in 8.5.6.

Although I don't know whether w/FM connections can be pooled
with nested inlines.  The last time I tested, it does not.  If
we did this:

     inline($cnxn, ...); // with db, table, u/p parameters
         inline(...);    // without db, table, u/p parameters
         /inline;
     /inline;

We still opened up a second connection for the inner, nested inline.

>>I can't remember off the top of my head, as I almost always
>>use raw -sql these days:
>
>The style of inline ("classic" vs. "sql') you use makes no difference
>as to whether or not the connections are pooled.
>
>If you're combining all your queries into one single inline and
>pulling out the various results with [resultset], you're sidestepping
>the issue. Interesting thought, though I think it would be difficult
>to stick to in practice.

There are some cases where it won't work, specifically when you
need to use Lasso to operate on the resultset, then update the
results in the database.  But it is great for retrieving the
last inserted record ID and other routine, utilitarian tasks.

Out of curiosity, what happens if you put the connection stuff
into the nested, inner inline?  Will that open a second
connection or will the parameters from the inner inline
(-database, -table, -username, and -password) be ignored?

     inline($cnxn, ...);
         inline($cnxn, ...);
         /inline;
     /inline;

--steve

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

12