|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
stripping down database results
i have a record that is returned by the database as domain/username. i want to be able to strip off "domain/" and just display "username". is this possible? if so, how would i go about doing this?
|
|
#2
|
||||
|
||||
|
Hi,
this should do the trick Code:
Dim lsTemp lsTemp = Split(nameofrecordvar,"/") Response.Write lsTemp(1) Kong. |
|
#3
|
|||
|
|||
|
i tried implementing it with what i have... but it didn't work. cmuser is the field that i am referring to...the format is "domain/username" i want to just display username
StrSQL = "Select Distinct CMUSER, CMLDAT, CMDENY, CMEXPD, CMLLOG, CMHITS from tblUserInfo where CMUSER='" & trim(session("strUserID")) & "'" Set adoRSWEBtest = adoConnWEBtest.Execute(StrSQL) Dim lsTemp lsTemp = Split(CMUSER,"/") %> <table width=75% cellspacing='1px'> <th class='Main'> <span id='SpaceImg'> <img src='Graphix/spacer.gif' width='600px' height='0px' valign='top'> <br></span> Account Summary & Statistics <br> <span id='SmNote'><% =lsTemp(1) %></span> </th> </tr> |
|
#4
|
||||
|
||||
|
Hi,
you need to reference the sql query var as well. Something like this should work: Code:
lsTemp = split(adoRSWEBtest("CMUSER"),"/")
Kong. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > stripping down database results |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|