Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8766693
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T16:37:03+00:00 2026-06-13T16:37:03+00:00

I have a problem with the return of a simple query Table San_ChaveBematech ID

  • 0

I have a problem with the return of a simple query

Table San_ChaveBematech

ID     Chave_Id     Credenciada_Id    Recibo   Impresso
55     571678       10                Test     0

Table San_CadastraBematech

ID     Maquina          Credenciada
5      000FEAB63D89     10
6      003067D6A4E7     10
7      003067D6A4D4     10

Query That I has some problem

SELECT San_ChaveBematech.Recibo
FROM San_ChaveBematech
JOIN San_CadastraBematech
ON San_ChaveBematech.Credenciada_Id = San_CadastraBematech.Credenciada
WHERE San_ChaveBematech.Credenciada_Id = 
       (SELECT top 1 credenciada 
        FROM San_CadastraBematech 
        WHERE maquina = '000FEAB63D89')
AND San_ChaveBematech.Impresso = 0

How It Works

I have an application (Windows Form) where my user will be registered. I’ll save her register in my San_CadastraBematech table. In my web application I can get some keys and, when I get it, I’ll save the data in San_ChaveBematech table. To print it, I do the query that I put here, but look, I have just one register in San_ChaveBematech but my query return the same register 3 times.

Can somebody help me ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T16:37:04+00:00Added an answer on June 13, 2026 at 4:37 pm
    SELECT top 1 Ch.Recibo
      FROM San_ChaveBematech Ch
      JOIN San_CadastraBematech Ca
        ON Ch.Credenciada_Id = Ca.Credenciada
     WHERE Ca.maquina = '000FEAB63D89'
       AND Ch.Impresso = 0;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a little simple problem. I want to perform a query on a
I have problem understanding what the return fibonacci( number-1 ) + fibonacci( number-2 )
I have a problem with Json formating returned from .ASMX I need to return
I have a problem when using jsonp to API HTTPS website. it will return
I have an odd problem when using the return result of a function and
I have a problem with the SQL statement detailed below. The query returns the
I have a simple mySQL problem-- I have two tables, one is a user's
I have a simple code to fetch users from db using sqlalchemy and return
I'm struggling with a (usually simple to deal with) problem. I have a database
I'm trying to create a simple form with sonata bundle. I have one problem

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.