Debug: Produto Object
(
    [chave] => 
    [codigo] => 
    [descricao] => 
    [grupo1] => 
    [grupo2] => 
    [grupo3] => 
    [inclusao] => 
    [tipo] => 
    [g_l] => 
    [g_l1] => 
    [g_l2] => 
    [g_icms] => 
    [g_comissao] => 
    [curva_abc] => 
    [curva_xyz] => 
    [local] => 
    [qme] => 
    [unid_med] => 
    [etiquetas] => 
    [est_minimo] => 
    [est_maximo] => 
    [custo_reposicao] => 
    [custo_medio] => 
    [custo_atual] => 
    [preco_venda] => 
    [preco_atacado] => 
    [preco_venda1] => 
    [ult_ven] => 
    [ult_compra] => 
    [alt_reposicao] => 
    [alt_medio] => 
    [alt_atual] => 
    [alt_venda] => 
    [alt_atacado] => 
    [alt_venda1] => 
    [peso] => 
    [obs] => 
    [deletado] => 
    [foto] => 
    [classificacao_fiscal] => 
    [auxiliar1] => 
    [ajuste_preco] => 
    [fornecedor] => 
    [etiqueta_prateleira] => 
    [imprime_etiqueta] => 
    [quant_preco_atacado] => 
    [quant_preco_venda1] => 
    [inativo] => 
    [cfop] => 
    [foradelinha] => 
    [aliq_ipi] => 
    [descricao_web] => 
    [_db] => DataBase Object
        (
            [db_driver:DataBase:private] => mysqli
            [db_host:DataBase:private] => 127.0.0.1
            [database:DataBase:private] => dbtachar
            [db_user:DataBase:private] => webtrade
            [db_password:DataBase:private] => T3760S
            [current_connection:DataBase:private] => ADODB_mysqli Object
                (
                    [databaseType] => mysqli
                    [dataProvider] => mysql
                    [hasInsertID] => 1
                    [hasAffectedRows] => 1
                    [metaTablesSQL] => SELECT TABLE_NAME, CASE WHEN TABLE_TYPE = 'VIEW' THEN 'V' ELSE 'T' END FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA=SCHEMA()
                    [metaColumnsSQL] => SHOW COLUMNS FROM `%s`
                    [fmtTimeStamp] => 'Y-m-d H:i:s'
                    [hasLimit] => 1
                    [hasMoveFirst] => 1
                    [hasGenID] => 1
                    [isoDates] => 1
                    [sysDate] => CURDATE()
                    [sysTimeStamp] => NOW()
                    [hasTransactions] => 1
                    [forceNewConnect] => 
                    [poorAffectedRows] => 1
                    [clientFlags] => 0
                    [substr] => substring
                    [port] => 
                    [socket] => 
                    [_bindInputArray] => 
                    [nameQuote] => `
                    [optionFlags] => Array
                        (
                            [0] => Array
                                (
                                    [0] => 5
                                    [1] => 0
                                )

                        )

                    [arrayClass] => ADORecordSet_array_mysqli
                    [multiQuery] => 
                    [_genIDSQL] => update %s set id=LAST_INSERT_ID(id+1);
                    [_genSeqSQL] => create table %s (id int not null)
                    [_genSeqCountSQL] => select count(*) from %s
                    [_genSeq2SQL] => insert into %s values (%s)
                    [_dropSeqSQL] => drop table %s
                    [database] => dbtachar
                    [host] => 127.0.0.1
                    [user] => webtrade
                    [password] => not stored
                    [debug] => 
                    [maxblobsize] => 262144
                    [concat_operator] => +
                    [length] => length
                    [random] => rand()
                    [upperCase] => upper
                    [fmtDate] => 'Y-m-d'
                    [true] => 1
                    [false] => 0
                    [replaceQuote] => \'
                    [charSet] => 
                    [metaDatabasesSQL] => 
                    [uniqueOrderBy] => 
                    [emptyDate] =>  
                    [emptyTimeStamp] =>  
                    [lastInsID] => 
                    [hasTop] => 
                    [readOnly] => 
                    [genID] => 0
                    [raiseErrorFn] => 
                    [cacheSecs] => 3600
                    [memCache] => 
                    [memCacheHost] => 
                    [memCachePort] => 11211
                    [memCacheCompress] => 
                    [sysUTimeStamp] => 
                    [noNullStrings] => 
                    [numCacheHits] => 0
                    [numCacheMisses] => 0
                    [pageExecuteCountRows] => 1
                    [uniqueSort] => 
                    [leftOuter] => 
                    [rightOuter] => 
                    [ansiOuter] => 
                    [autoRollback] => 
                    [fnExecute] => 
                    [fnCacheExecute] => 
                    [blobEncodeType] => 
                    [rsPrefix] => ADORecordSet_
                    [autoCommit] => 1
                    [transOff] => 0
                    [transCnt] => 0
                    [fetchMode] => 
                    [null2null] => null
                    [bulkBind] => 
                    [_oldRaiseFn] => 
                    [_transOK] => 
                    [_connectionID] => mysqli Object
                        (
                            [affected_rows] => -1
                            [client_info] => mysqlnd 5.0.11-dev - 20120503 - $Id: 76b08b24596e12d4553bd41fc93cccd5bac2fe7a $
                            [client_version] => 50011
                            [connect_errno] => 0
                            [connect_error] => 
                            [errno] => 1064
                            [error] => You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY chave DESC LIMIT 0,1' at line 1
                            [error_list] => Array
                                (
                                    [0] => Array
                                        (
                                            [errno] => 1064
                                            [sqlstate] => 42000
                                            [error] => You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY chave DESC LIMIT 0,1' at line 1
                                        )

                                )

                            [field_count] => 0
                            [host_info] => 127.0.0.1 via TCP/IP
                            [info] => 
                            [insert_id] => 0
                            [server_info] => 5.5.62-log
                            [server_version] => 50562
                            [stat] => Uptime: 5035266  Threads: 3  Questions: 293568707  Slow queries: 4456  Opens: 37476  Flush tables: 465  Open tables: 492  Queries per second avg: 58.302
                            [sqlstate] => 00000
                            [protocol_version] => 10
                            [thread_id] => 79309942
                            [warning_count] => 0
                        )

                    [_errorMsg] => You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY chave DESC LIMIT 0,1' at line 1
                    [_errorCode] => 
                    [_queryID] => 
                    [_isPersistentConnection] => 
                    [_evalAll] => 
                    [_affected] => 
                    [_logsql] => 
                    [_transmode] => 
                    [databaseName] => dbtachar
                )

            [current_query:DataBase:private] => SELECT * FROM produtos WHERE codigo =  ORDER BY chave DESC LIMIT 0,1 
            [last_error:DataBase:private] => You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY chave DESC LIMIT 0,1' at line 1
            [last_id] => 
            [connection_pool:DataBase:private] => Array
                (
                )

        )

    [_table] => produtos
    [_pk] => chave
    [_display_field] => descricao
    [_default_order] => codigo
    [_alias] => produtos
    [_join_tables] => Array
        (
        )

    [_error_field] => Array
        (
        )

    [_field_types] => Array
        (
        )

    [_field_format] => Array
        (
        )

    [_field_format_paramns] => Array
        (
        )

    [_field_function] => Array
        (
        )

    [_field_function_paramns] => Array
        (
        )

)
Debug: