Error en ASP

Tengo una aplicativo en ASP sobre windows xp con base de datos SQL server
y tengo en siguiente error
The page cannot be displayed
> There is a problem with the page you are trying to reach and it cannot
be
> displayed.
>
> Please try the following:
> · Click the Refresh button, or try again later.
> · Open the 192.168.1.1 home page, and then look for links to the
information
> you want.
> HTTP 500.100 - Internal Server Error - ASP error
> Internet Information Services
>
> Technical Information (for support personnel)
> · Error Type:
> Microsoft OLE DB Provider for ODBC Drivers (0x80040E37)
> [Microsoft][ODBC SQL Server Driver][SQL Server]El nombre de objeto
> 'tmpMARTHA3581' no es válido.
> /alfa/radicaenviada.asp, line 355
> · Browser Type:
> Mozilla/4.0 (compatible; MSIE 6.0; Windows 98)
> · Page:
> POST 521 bytes to /alfa/radicaenviada.asp
> · POST Data:
>
txtFecha=10%2F4%2F2004&txtHora=12%3A24%3A17+PM&cmbDependencia=7&txtNumID=&tx
>
tFuenteRad=&txtDescFuente=&txtCodProc=4&txtNomProc=PERSONERIA+MUNICIPAL&txtN
> omCiu=MANIZALES-CALDAS&txtDetalle=CGM+682+JULIO+ . . .
> · Time:
> Monday, October 04, 2004, 12:26:32 PM
> · More information:
> Microsoft Support
Seran permisos sobre SQL del usuario
Gracias
Respuesta
1
¿Y en la linea 355 de la página radicaenviada.asp que tienes?
¿Y dónde creas 'tmpMARTHA3581'?
Mandame esos dos trozos de código para saber donde puede estar el fallo.
Etas son las lineas de código donde presenta error.
Sera que son perfiles de accesos del usuario
intRandomTableNumber = Int((30000 * Rnd) + 1)
strTmpTableName = "tmp" & Session("usuario") & intRandomTableNumber
strSQL = "begin tran declare @numra as float select @numra=(select radinide from ctrl) "
strSQL = strSQL & "create table " & strTmpTableName & " (r float) "
strSQL = strSQL & "if @@error<>0 begin rollback tran goto on_error end "
strSQL = strSQL & "insert into " & strTmpTableName & " values (@numra) "
strSQL = strSQL & "if @@error<>0 begin rollback tran goto on_error end "
strSQL = strSQL & "insert into registro values(@numra,getdate(),NULL,'"
strSQL = strSQL & Request.Form("txtCodProc") & "','"
strSQL = strSQL & Request.Form("txtCodNat") & "','"
strSQL = strSQL & Request.Form("cmbDependencia") & "',"
strSQL = strSQL & strFuenteRad & ",'"
strSQL = strSQL & Request.Form("txtDetalle") & "',NULL,NULL,'"
strSQL = strSQL & Request.Form("txtAnexos") & "','"
strSQL = strSQL & Session("usuario") & "','"
strSQL = strSQL & Request.Form("txtNumID") & "','"
strSQL = strSQL & Request.Form("txtCodExp") & "','"
strSQL = strSQL & Request.Form("txtCodMed") & "',getdate(),'A','" & Session("usuario") & "','"
strSQL = strSQL & Request.Form("cmbSeries") & "',NULL) "
strSQL = strSQL & "if @@error<>0 begin rollback tran goto on_error end "
strSQL = strSQL & strSQLInsEnterar
strSQL = strSQL & "update ctrl set radinide=radinide+1 "
strSQL = strSQL & "if @@error<>0 begin rollback tran goto on_error end "
strSQL = strSQL & "commit tran on_error:"
'on error resume next
'Response.Write strSQL
cn.Execute strSQL
if err then
Session("MensajeTransaccion")=Err.Description
cn.Close
'response.redirect "tranfailure.asp"
else
strSQL = "select r from " & strTmpTableName ******* esta es la linea donde saca error
rs.Open strSQL, cn
intNumRadicado = rs("r")
rs.close
Bueno se me ocurre que la linea donde te da el error:
strSQL = "select r from " & strTmpTableName
sustituyela por
response.write("select r from " & strTmpTableName)
para ver que mete realmente y comenta el resto de las lineas
rs.Open strSQL, cn
intNumRadicado = rs("r")
rs.close
Con lo que te muestre en la página, vete a SQL Server y ejecutalo a ver que error te da.
No se me ocurre mucho más...
¿No se si conoces visual foxpro?
¿Mi pregunta es?
¿Yu trabajo ASP bajo Dreamweaver pero quiero hacer un seguimiento a la ejecución de un programa cualquiera?
Eso se puede hacer como se hace en visual con un Set step on
Bueno para DreamWeaver tan solo conozco un debugger para javascript. Yo trabajo con MX (no con MX 2004) igual el 2004 incluye algo de lo que preguntas.

Añade tu respuesta

Haz clic para o

Más respuestas relacionadas