Search Result

Collapse
2 results in 0.0013 seconds.
Keywords
Members
Tags
mid
  •  

  • JSchaenzle
    started a topic Passing strings to and from functions
    in C

    Passing strings to and from functions

    I am trying to pass a string to a Mid() function, return a portion of the string, and then convert that portion to an int. My attempt looks like this..

    char * ReceivedStr;
    char * Mid(char * inString, int Start, int Length );


    main()
    {
    int i;
    int dis;
    char * Distance;
    ReceivedStr = "Move125";

    Distance = Mid(ReceivedStr , 4, 3);...
    See more | Go to post

  • Marjeta
    started a topic extracting info from LDAP column?

    extracting info from LDAP column?

    I have a table with one of the columns being ldap info. Example value would be:
    ou=FOO,ou=BAR,o =XYZ,dc=WORLD

    From this I would like to extract the first string, in this case FOO.

    My last attempt was:

    [CODE=mysql]SELECT 1+instr(T.ldap, "=") as startpos,
    instr(T.ldap,", ") as endpos,
    mid(T.ldap,star tpos,endpos-startpos)
    FROM myTable...
    See more | Go to post
    Last edited by mwasif; Mar 12 '09, 07:22 PM. Reason: Added CODE tags
Working...